<?php
    
    /**
     * Created by PhpStorm.
     * User: Administrator
     * Date: 2017/4/12
     * Time: 10:29
     */
//    require '../Animals.php';
    class Dog extends Animals
    {
        public $kind="狗狗";
    
        /**
         * Dog constructor.
         * @param $weight
         * @param $age
         * @param $name
         */
        function __construct($weight,$age,$name)
        {
        $this->weight = $weight;
        $this->age = $age;
        $this->name = $name;
        echo "动物构造函数结束"."体重是：".$weight."年龄是：".$age."名字是".$name."<br>";
        }
    
        /**
         * @return string
         */
        public function getKind(): string
        {
            return $this->kind;
        }
        public function call(){
            echo $this->kind."汪汪叫"."<br>";
        }
    }
  
//    $nan = new Dog('12','12','142');
//    $nan->call();
    